import java.io.IOException;
import java.io.RandomAccessFile;


/*
 * Class for datatype of the columns.
 * this is the base class which is extended by
 * all the specific datatypes.
 */
public class datatype {

	int type;
	int length;

	public datatype()
	{
		type=0;
		length=0;
	}
	public datatype(int type, int length) 
	{
		this.type = type;
		this.length = length; 
	}

	public void write(String data, int length) throws IOException
	{
		RandomAccessFile fi= new RandomAccessFile(heap.f,"rw");
		fi.seek(0);
		fi.writeChars(data);
		fi.close();
		length=data.length();
	
	}
	public String read(int length) throws IOException
	{
		return "";
	}
	public int compares(String x, String y) throws IOException
	{
		return -2;
	}
}
